﻿<%@ Control Language="c#" AutoEventWireup="false" Inherits="Web.Control.WWW.Course.Course" %>
<div class="common">
	<div class="submenunew">
		<div class="submenu_l">
				<div class="unsub">
					<div class="unsubsel">
					<a href="/teaching/"><span>
				<%if(Page.Request.RawUrl.ToLower().IndexOf("/teaching/")>-1){%>
					<strong><%=GetText("M0036")%></strong></span></a></div>
					<div><img src="/Images/submenu_arrow.gif" /></div>
				<%} else{%>
					<%=GetText("M0036")%></span></a></div>
					<div><img src="/Images/submenu_arrownone.gif" /></div>
				<%}%>
				</div>
				<div class="unsub">
					<div class="unsubsel">
					<a href="/course/"><span>
				<%if(Page.Request.RawUrl.ToLower().IndexOf("/course/")>-1){%>
					<strong><%=GetText("M0037")%></strong></span></a></div>
					<div><img src="/Images/submenu_arrow.gif" /></div>
				<%} else{%>
					<%=GetText("M0037")%></span></a></div>
					<div><img src="/Images/submenu_arrownone.gif" /></div>
				<%}%>
				</div>
				<div class="unsub">
					<div class="unsubsel">
					<a href="/teach/join.htm"><span>
				<%if(Page.Request.RawUrl.ToLower().IndexOf("/teach/join.htm")>-1){%>
					<strong><%=GetText("TP100")%></strong></span></a></div>
					<div><img src="/Images/submenu_arrow.gif" /></div>
				<%} else{%>
					<%=GetText("TP100")%></span></a></div>
					<div><img src="/Images/submenu_arrownone.gif" /></div>
				<%}%>
				</div>
				<div class="cleartm"></div>
		</div>
		<div class="submenu_r"><input id="textKey" type="text" class="common_search" /><a href="#" id="btsearch" class="buttonimg" onclick="Search()" ><img src="/Images/icon_search19.gif" border="0" class="img" /></a></div>
		<div class="cleartm"></div>
	</div>
</div>
<div class="common">
	<div id="new_body">
		<div id="body_900">
			<div id="body_left"></div>
			<div id="body_main">
				<div class="submenuN">
					<div class="submenuN_position">
						<div class="submenuN_title">
							<div class="submenuN_Btitle">
								<h1><%=Lx.Web.Common.UI.Globals.HtmlStrippedText(CourseInfo.Title)%></h1>
							</div>
							<div class="course_fliter">
									<div class="floatl">
										<p class="text14">For learning: <%=BLF.StaticData.HaveLanguageImage(CourseInfo.LanguageLearn) ? "<img src='/Images/language_" + CourseInfo.LanguageLearn + ".gif' />" : ""%> <%=BLF.StaticData.GetLanguageText(CourseInfo.LanguageLearn) %></p>
										<p>Course level: Beginner - Advanced <img src="/Images/Level<%=CourseInfo.Level.Substring(0, 1) %>.gif" /> <%=CourseInfo.Level.Length > 1 ? " - <img src='/Images/Level" + CourseInfo.Level.Substring(CourseInfo.Level.Length - 1, 1) + ".gif' />" : ""%></p>
										<p>Course Type: <!--a href="<%=WWWHost%>/course/type-<%=CourseInfo.CType %>.htm"--><%=BLF.WWW_User.Teach.Teach.GetCTypeText(CourseInfo.CType)%></p>
										<p class="grey12">Teach using: <%=GetBaseLanText(CourseInfo.BaseLanguage)%></p></div>
									<div class="floatr">
										<div class="layer_contentA5">
										<%if(MemberNo!=CourseInfo.MemberNo&&(bool)ArrCourseInfo[3]) {%>
											<%if(LessonList.Count>0) {%>
										<p align="center" class="price"><span class="price_num"><%=CourseInfo.Price.ToString("N0") %></span> ITC / hour</p>
										<p><%if (((Lx.Web.Common.UI.TDTPageBase)Page).IsAffirm){%><a href="<%=WWWHost %>/session/addasession.htm?tid=<%=CourseInfo.MemberNo%>&cid=<%=CID%>" class="specgbtn"><%}else{ %><a href="#" class="specgbtn" onclick="NotAffirm()"><%} %><span><%=GetText("Book Lesson")%></span></a></p>
										<p><a href="#" class="specbtn" <%=(((Lx.Web.Common.UI.TDTPageBase)Page).IsAffirm)?"onclick=\"$Getmail$('"+CourseInfo.MemberNo+"')\"":"onclick=\"NotAffirm()\""%>><span><%=GetText("TP128") %></span></a></p>
											<%} %>									
										<%} else if(MemberNo==CourseInfo.MemberNo&&(bool)ArrCourseInfo[3]){%>
											<div class="margin5" style="border-bottom:1px #eee solid; padding-bottom:5px; width:auto; text-align:right">
												<span class="Black12UU"><a href="<%=WWWHost %>/course/editcourse-<%=CID %>.htm"><%=GetText("Edit Course") %></a></span>
											</div>
										<%} %>
										</div>
									</div>							
									<div class="clear"></div>
							</div>
							<div class="submenuN_button">
							</div>
						</div>
					</div>
				</div>
				<div class="Center9001n">
					<div class="Center9001Right">
						<div class="center9001content">
							<div class="teach_area">
									<div class="courses_col">
										<div><%=CourseInfo.Desc %></div>
										<p><img src="/Images/icon_common_flag.gif" align="absmiddle" /> <a href="#" onclick="$Feedback$()"><%=GetText("PB010") %></a></p>
									</div>
									<div class="courses_col">
										<h3 class="spectitleT">Lessons</h3>
										<%if (LessonList.Count > 0){%>
										<div>
											<ul class="lesson_ul">
											<%foreach(Model.WWW_User.Teach.LessonModel lm in LessonList) {%>
											    <li><span class="blue14bu"><a href="<%=WWWHost %>/lesson/<%=lm.LID %>"><%=GetText("Lesson {0} {1}", new string[] { lm.Chapter.ToString(), Lx.Web.Common.UI.Globals.HtmlStrippedText(lm.Title) })%></a></span></li>
											<%} %>
											</ul>									
										</div>
										<%} else {%><p class="grey12">No any lessons in this course.</p><%} %>
										<%if(MemberNo==CourseInfo.MemberNo&&(bool)ArrCourseInfo[3]) {%>
										<p><img src="/Images/icon_add.gif" width="16" height="16" align="absmiddle" /> <a href="<%=WWWHost %>/lesson/addLesson-<%=CID %>.htm">Add a Lesson</a></p>
										<%} %>
									</div>
									<div class="courses_col">
										<h3 class="spectitleT">Course details</h3>
										<div class="course_detail">
											<p>												
												<%if (CourseInfo.CreateDate==(DateTime)ArrCourseInfo[0]) {%>
												<a href="<%=WWWHost %>/<%=CourseInfo.MemberNo %>T.htm"><%=CourseInfo.Nickname %></a>  posted this course on <%=CourseInfo.CreateDate.ToString("MMM d, yyyy HH:mm", new System.Globalization.CultureInfo(Lx.Web.Common.UI.Globals.Language))%> 
												<%} else{%>
												<a href="<%=WWWHost %>/<%=CourseInfo.MemberNo %>T.htm"><%=CourseInfo.Nickname %></a> modified this course on <%=((DateTime)ArrCourseInfo[0]).ToString("MMM d, yyyy HH:mm", new System.Globalization.CultureInfo(Lx.Web.Common.UI.Globals.Language))%> 
												<%} %>
											</p>
											<p>Tags: <%foreach(string tag in TagList) {%><a href="<%=WWWHost %>/course/tag/<%=HttpUtility.UrlEncode(tag) %>.htm"><%=Lx.Web.Common.UI.Globals.HtmlStrippedText(tag)%></a>&nbsp;&nbsp;<%} %></p>
											<p>Sessions taught: <%=CourseInfo.Sessions == 0 ? CourseInfo.Sessions +" session":"<a href='"+WWWHost +"/course/"+CID+"/sessions.htm'>"+CourseInfo.Sessions +" sessions</a>" %></p>
											<p>Copyright: <%=GetLicense(CourseInfo.License)%></p>
											<p>Views: <%=CourseInfo.Views %></p>
										</div>
									</div>
									<%if (rptSessions.Items.Count > 0){%>
									<div class="courses_col">
										<h3 class="spectitleT">Latest sessions</h3>
										<div>
										<asp:Repeater ID="rptSessions" runat="server">
										<ItemTemplate>
											<div class="courses_comment">
												<div class="courses_comment_avatar Pic50"><a class="photo_50" href='<%#WWWHost %>/<%#Eval("SNO") %>.htm' ><img src='<%#Eval("SAvatar").ToString() == ""?"/Images/No_pic.gif":Eval("SAvatar").ToString() %>' alt="<%#Eval("SNickname") %>" /></a>
												</div>
												<div class="courses_comment_Bacontent">
													<div class="courses_comment_acontent">
														<span class="grey12"><a href='<%#WWWHost %>/<%#Eval("SNO") %>.htm'><%#Eval("SNickname") %></a> feedback on  <%#((DateTime)Eval("HappenDate")).ToString("MMM d, yyyy", new System.Globalization.CultureInfo(Lx.Web.Common.UI.Globals.Language)) %></span>
														<div class="margin5D"><%#Eval("SToTDesc")%></div>
													</div>
													<div class="courses_comment_delete"><a href="<%#WWWHost %>/lesson/<%#Eval("LID") %>"><%#GetText("Lesson {0} {1}", new string[] { Eval("LChapter").ToString(), Lx.Web.Common.UI.Globals.HtmlStrippedText(Eval("LTitle").ToString()) })%></a><p class="grey11">Professional: <%#Eval("Professional") %><br />Knowledgeable: <%#Eval("Knowledgeable") %><br />Helpful: <%#Eval("Helpful") %></p>
													</div>
													<div class="Clear"></div>
												</div>
												<div class="Clear"></div>
											</div>
										</ItemTemplate>
										</asp:Repeater>														
										<%if (rptSessions.Items.Count > 5){%>
										<p align="right"><a href="<%=WWWHost %>/course/<%=CID%>/sessions.htm">More sessions</a></p>
										<%} %>
										</div>
									</div>
									<%} %>
									<!--div class="courses_col">
										<p><strong><%=GetText("{0}'s courses",new string[]{CourseInfo.Nickname}) %></strong></p>
										<div>
											<ul class="lesson_ul">
												<asp:Repeater ID="rptTeaOthCourse" runat="server">
												<ItemTemplate>
													<li><a href="<%#WWWHost %>/course/<%#Eval("CID") %>"><%#Lx.Web.Common.UI.Globals.HtmlStrippedText(Eval("Title").ToString())%></a></li>
												</ItemTemplate>
												</asp:Repeater>
											</ul>
											<p align="right"><a href="<%=WWWHost %>/course/"><%=GetText("More courses") %></a></p>
										</div>
									</div-->
							</div>
						</div>
					</div>
					<div class="Center9001Left">
						<div class="right_layerA">
							<div class="layer_contentA">
								<div class="layer_contentA5">
									<div class="card">
										<div class="floatl"><a href="<%=WWWHost %>/<%=CourseInfo.MemberNo %>T.htm"><img src='<%=CourseInfo.Avatar == ""?"/Images/No_pic.gif":CourseInfo.Avatar %>' alt="<%=CourseInfo.Nickname %>" width="50" height="50" /></a></div>
										<div class="floatr"><strong><%=CourseInfo.Nickname %></strong>
										<%=CourseInfo.TeacherType=="1"?"<p><span class='status_TEdisplay'>"+GetText("C0116"):"<p><span class='status_TUdisplay'>"+GetText("C0120")%></span></p><span class="grey11"><%=GetText("C0102",new string[]{BLF.StaticData.GetCountryText(CourseInfo.Nationality)}) %></span>
										
										</div>
										<div class="cleartm"></div>
									</div>
								</div>
							</div>
						</div>
						<div class="right_layerA">
							<div class="layer_contentA">
								<div class="layer_contentA5">
									<p><strong>Course Schedule</strong></p>
									<%if (TimeAvaila != null && TimeAvaila.Count > 0){%>
									<p class="grey12"><%=GetTimezoneText(ArrCourseInfo[4].ToString() != "" ? ArrCourseInfo[4].ToString() : "0")%></p>
									<ul>
									<% int tle = TimeAvaila.Count; for (int i = 0; i < tle; i++){if (i == 0){%><li><div class="schedule_day"><%=BLF.WWW_User.Users.User.GetWeek(TimeAvaila[i].Week)%></div><div class="schedule_time"><%=TimeAvaila[i].FromTime%>-<%=TimeAvaila[i].ToTime%><%}else if (TimeAvaila[i].Week != TimeAvaila[i - 1].Week && i != tle - 1){ %></div><div class="clear"></div></li>
										<li><div class="schedule_day"><%=BLF.WWW_User.Users.User.GetWeek(TimeAvaila[i].Week)%></div><div class="schedule_time"><%=TimeAvaila[i].FromTime%>-<%=TimeAvaila[i].ToTime%><%}else if (i == tle - 1){ %><%if (TimeAvaila[i].Week == TimeAvaila[i - 1].Week){%><br /><%=TimeAvaila[i].FromTime%>-<%=TimeAvaila[i].ToTime%></div></li><%}else { %></div><div class="clear"></div></li>
										<li><div class="schedule_day"><%=BLF.WWW_User.Users.User.GetWeek(TimeAvaila[i].Week)%></div><div class="schedule_time"><%=TimeAvaila[i].FromTime%>-<%=TimeAvaila[i].ToTime%></div><div class="clear"></div></li><%}} %><%else if (TimeAvaila[i].Week == TimeAvaila[i - 1].Week){%><br /><%=TimeAvaila[i].FromTime%>-<%=TimeAvaila[i].ToTime%><%} %>
										<%} %>

									</ul>
									<div class="clear"></div>
									<%} %>
								</div>
							</div>
						<!--div class="right_layerA">
							<div class="layer_contentA">
							</div>
						</div>
						<div class="right_layerA">
							<div class="layer_contentA">
								<h4><%=GetText("Related {0} courses", new string[] { BLF.StaticData.GetLanguageText(CourseInfo.LanguageLearn) })%></h4>
								<div class="layer_contentA5">
									<ul class="common_rightline">
										<asp:Repeater ID="rptOtherCourse" runat="server">
											<ItemTemplate>
												<li><a href="<%#WWWHost %>/course/<%#Eval("CID") %>"><%#Lx.Web.Common.UI.Globals.HtmlStrippedText(Eval("Title").ToString())%></a></li>
											</ItemTemplate>
										</asp:Repeater>
									</ul>
									<p align="right"><a href="<%=WWWHost %>/course/"><%=GetText("More courses") %></a></p>
								</div>
							</div>
						</div-->
					</div>
					<div class="clear"></div>
				</div>
			</div>
			<div id="body_right"></div>
			<div class="clear"></div>
		</div>
		<div id="body_900F"></div>
	</div>
</div>
<script>
var title='<%=GetText("CourseSchedule") %>';
</script>